<%@ tag language="java" pageEncoding="UTF-8" body-content="empty" trimDirectiveWhitespaces="true"%>
<%@ attribute name="id" type="java.lang.String" required='true' description="ajax请求的id"%>
<%@ attribute name="formSubmit" type="java.lang.Boolean" description="是否需要操作一个表单，true/false，默认为false，设置了这个属性还需要设置formQuery以此告知哪个表单"%>
<%@ attribute name="formQuery" type="java.lang.String" description="jquery的form查询，指明你需要用哪个form，例：若form表单的id='queryOrgFrm'，那么你可以设置formQuery='#queryOrgFrm'"%>
<%@ attribute name="url" type="java.lang.String" required="true"%>
<%@ attribute name="type" type="java.lang.String" description="post/get/delete...,默认为get"%>
<%@ attribute name="dataType" type="java.lang.String" description="ajax的dataType,默认为json"%>
<%@ attribute name="async" type="java.lang.Boolean" description="同步/异步，true/false"%>
<%@ attribute name="timeout" type="java.lang.Integer" description="ajax的超时时间，单位：毫秒"%>
<%@ attribute name="cache" type="java.lang.Boolean" description="是否使用缓存，true/false"%>
<%@ attribute name="autoSend" type="java.lang.Boolean" description="设置是否自动发送ajax请求，默认不自动发送，defualut=false"%>
<%@ attribute name="silent" type="java.lang.Boolean" description="发送Ajax请求时，是否设为加载中状态，默认silent=false"%>
<%@ attribute name="onSuccess" type="java.lang.String" description="响应成功时调用的函数，onSuccess(data,status,xhr)"%>
<%@ attribute name="onError" type="java.lang.String" description="响应失败时调用的函数，onError(xhr,textStatus,errorThrown)"%>
<%@ attribute name="onBeforeSend" type="java.lang.String" description="发送请求前执行函数"%>
<%@ attribute name="onComplete" type="java.lang.String" description="请求完成执行函数"%>
<%@ attribute name="onServiceError" type="java.lang.String" description="业务错误，onServiceError(data,status,xhr)"%>
<%@ attribute name="contentType" type="java.lang.String" description="对contentType进行设置，默认'application/json'，常用的有application/x-www-form-urlencoded"%>
<%@ attribute name="data" type="java.lang.String" description="json data"%>
<%@ attribute name="prompt" type="java.lang.Boolean" description="可选项：messager/dialog,是否根据后台返回的message提示，当存在onSuccess时，该属性功能失效"%>
<%@ attribute name="htmlEncodeNames" type="java.lang.String" description="指定需要htmlEncode的属性，逗号分隔"%>
<%@ attribute name="successMonitors" type="java.lang.String" description="成功回调监听者，逗号分隔"%>
<%@ attribute name="respDataKey" type="java.lang.String" description="响应数据key，用该key可以取值"%>
	
<script type="text/javascript">
(function(){
	window.TagSupport.ajax({
		'id':"${id}",'formSubmit':"${formSubmit}",'formQuery':"${formQuery}",'url':"${url}",'type':"${type}",'dataType':"${dataType}",'async':"${async}",'timeout':"${timeout}",'cache':"${cache}",
		'onSuccess':"${onSuccess}",'onError':"${onError}",'autoSend':"${autoSend}",'silent':"${silent}",'onBeforeSend':"${onBeforeSend}",'onComplete':"${onComplete}",'contentType':"${contentType}",
		'onServiceError':"${onServiceError}",'data':"${data}",'prompt':"${prompt}", 'htmlEncodeNames':"${htmlEncodeNames}", 'successMonitors':"${successMonitors}", 'respDataKey':"${respDataKey}"
	});
})();
</script>